home *** CD-ROM | disk | FTP | other *** search
/ The Arsenal Files 8 / The Arsenal Files Collection #8 (Arsenal Computer) (1996).ISO / business / ztree24.zip / INSTALL.BAT < prev    next >
DOS Batch File  |  1996-10-15  |  7KB  |  135 lines

  1. @echo off
  2. cls
  3. if [%1]==[] goto instruct
  4. if [%2]==[] goto instruct
  5. echo  
  6. if EXIST %1\CT.O goto doinst
  7. echo  
  8. echo ┌──────────────────────────────────────────────────────────────────
  9. echo │  The CALLING TREE could not be found in this path: {%2}
  10. echo ╘══════════════════════════════════════════════════════════════════
  11. goto 2inst
  12. :doinst
  13. if EXIST %2\??.O goto overnew
  14. echo    ┌───────────────────────────────────────────────────────────────────╖
  15. echo    │                                                                   ║
  16. echo    │ This is an ORIGINAL {NEW} installation of THE CALLING TREE.       ║
  17. echo    │ NO changes will be made to your AUTOEXEC.BAT or CONFIG.SYS files! ║
  18. echo    │ A system environment variable 'ZTREE' will be set to CT location  ║
  19. echo    │                                                                   ║
  20. echo    ╘═══════════════════════════════════════════════════════════════════╝
  21. echo Install NEW version from [%1\] to [%2\]?
  22. goto crct
  23. :overnew
  24. echo    ┌───────────────────────────────────────────────────────────────────╖
  25. echo    │ ***  Old CALLING TREE files have been detected  ***               ║
  26. echo    │ This is an UPGRADE installation of THE CALLING TREE.              ║
  27. echo    │                                                                   ║
  28. echo    │ This installation procedure will rename some of the appropriate   ║
  29. echo    │ older files and then copy the new files.                          ║
  30. echo    │ NO changes will be made to your AUTOEXEC.BAT or CONFIG.SYS files! ║
  31. echo    │                                                                   ║
  32. echo    ╘═══════════════════════════════════════════════════════════════════╝
  33. echo Install UPGRADE version from [%1\] to [%2\]?
  34. :crct
  35. echo Correct?...
  36. echo  
  37. echo Press 'CONTROL C' to cancel or any other key to continue installation
  38. pause >nul
  39. if EXIST %2\CT.O goto renamect
  40. md %2
  41. goto copyct
  42. :renamect
  43. echo  
  44. echo Renaming Old files....
  45. if EXIST %2\??OLD.O del %2\??old.o >nul
  46. ren %2\??.o %2\??old.o >nul
  47. echo  
  48. echo Copying New files, One Moment....
  49. copy %1\*.* %2\ >nul
  50. cls
  51. echo  
  52. echo   ┌─────────────────────────────────────────────────────────────────────────╖
  53. echo   │  The OLD version of THE CALLING TREE has been rename as ??OLD.*.  The   ║
  54. echo   │  file extensions were kept the same.                                    ║
  55. echo   │                                                                         ║
  56. echo   │  The NEW version of THE CALLING TREE has been copied into the old       ║
  57. echo   │  CALLING TREE directory.                                                ║
  58. echo   │                                                                         ║
  59. echo   │  Step....                                                               ║
  60. echo   │  1. Set a system environment variable 'ZTREE' equal to CTREE directory  ║
  61. echo   │  2. Make sure you are in THE CALLING TREE directory now.                ║
  62. echo   │  3. To start the program type: 'CT' [ENTER].                            ║
  63. echo   │  4. CT will automatically detect any old data files (if any) and        ║
  64. echo   │     convert that data. All old data files will be preserved as ???old.* ║
  65. echo   │  5. If all is working fine you will want to manually delete all files   ║
  66. echo   │     in your CALLING TREE directory with the 'old' in the file name.     ║
  67. echo   ╘═════════════════════════════════════════════════════════════════════════╝
  68. goto endchg
  69. :copyct
  70. echo  
  71. echo Copying New files, One Moment....
  72. copy %1\*.* %2\ >nul
  73. cls
  74. echo  
  75. echo   ┌─────────────────────────────────────────────────────────────────────────╖
  76. echo   │  The NEW version of THE CALLING TREE has been copied to %2              ║
  77. echo   │                                                                         ║
  78. echo   │  a. Make sure you are in THE CALLING TREE directory now.                ║
  79. echo   │  b. Make sure the system environment variable ZTREE is set.             ║
  80. echo   │  c. To start the program type: 'CT' [ENTER].                            ║
  81. echo   │  d. If you have a registration number you may enter it in the           ║
  82. echo   │     Operator Information screen at start up.                            ║
  83. echo   ╘═════════════════════════════════════════════════════════════════════════╝
  84. goto endchg
  85. :instruct
  86. cls
  87. :2inst
  88. echo   ┌─────────────────────────────────────────────────────────────────────────╖
  89. echo   │  THE CALLING TREE - Installation                                        ║
  90. echo   │                                                                         ║
  91. echo   │  You MUST use this 'INSTALL' program to directly upgrade an older       ║
  92. echo   │  version of THE CALLING TREE.  This 'Install' program will install the  ║
  93. echo   │  new version over top of the old version in the old version directory.  ║
  94. echo   │                                                                         ║
  95. echo   │  Otherwise, if you are just installing THE CALLING TREE for the first   ║
  96. echo   │  time, you may 'Install' or DOS Copy this new version to a New          ║
  97. echo   │  directory on your hard disk.  Switch to that directory and type 'CT'   ║
  98. echo   │  to start.  You may copy (Import) the Old Data files once installed.    ║
  99. echo   │                                                                         ║
  100. echo   │  Note: If you have unarchived the program in a new directory on your    ║
  101. echo   │  systems' hard disk, then set the system environment variable 'ZTREE'   ║
  102. echo   │  equal to the directory where CT is located and type 'CT' to start.     ║
  103. echo   │                                                                         ║
  104. echo   │  ----------        INSTALLATION COMMAND PARAMETERS     ---------------  ║
  105. echo   │  INSTALL {From DRIVE:\DIRECTORY} {To DRIVE:\DIRECTORY}                  ║
  106. echo   │  Example: INSTALL B: C:\CTREE                                           ║
  107. echo   │  Note: You must NOT include '\' as last character in path               ║
  108. echo   │                                                                         ║
  109. echo   ╘═════════════════════════════════════════════════════════════════════════╝
  110. goto veryend2
  111. :endchg
  112. c:
  113. cd %2
  114. if EXIST cb.o goto delfil
  115. d:
  116. cd %2
  117. if EXIST cb.o goto delfil
  118. e:
  119. cd %2
  120. if EXIST cb.o goto delfil
  121. f:
  122. cd %2
  123. if EXIST cb.o goto delfil
  124. g:
  125. cd %2
  126. if cb.o goto delfil
  127. goto veryend2
  128. :delfil
  129. del %2\ztree*.* >nul
  130. :veryend
  131. dir ct*.* /w
  132. set ztree=%2
  133. :veryend2
  134.  
  135.